\documentclass{ctexart}
\usepackage{listings}%插入代码
\usepackage{geometry}%设置页面大小边距等
\usepackage{graphicx}%插入图片
\usepackage{amssymb}%为了用\mathbb
\usepackage{amsmath}%数学方程的显示
\usepackage{listings}%插入代码
\usepackage{fancyhdr}%设置页眉页脚
\usepackage{lastpage}%总页数
\usepackage{hyperref}%引用网页
\usepackage{xcolor}
\usepackage{tikz}



\geometry{a4paper,left=2cm,right=2cm,top=2cm,bottom=2cm}%一定要放在前面！
\pagestyle{fancy}%设置页眉页脚
\lhead{陈冠宇\ 3200102033}%页眉左
\chead{Numerical Methods for Differential Equations}%页眉中
\rhead{HW1}%章节信息
\cfoot{\thepage/\pageref{LastPage}}%当前页，记得调用前文提到的宏包
\lfoot{Zhejiang University}
\rfoot{School of Mathematical Sciences}
\renewcommand{\headrulewidth}{0.1mm}%页眉线宽，设为0可以去页眉线
\renewcommand{\footrulewidth}{0.1mm}%页脚线宽，设为0可以去页眉线
\setlength{\headwidth}{\textwidth}

\hypersetup{%设置网页链接颜色等
    colorlinks=true,%链接将会有颜色，默认是红色
    linkcolor=blue,%内部链接，那些由交叉引用生成的链接将会变为蓝色（blue）
    filecolor=magenta,%链接到本地文件的链接将会变为洋红色（magenta）
    urlcolor=blue,%链接到网站的链接将会变为蓝绿色（cyan）
    }

\newtheorem{theorem}{Theorem}
\newtheorem{proof}{Proof}
\newtheorem{solution}{Solution:}

\title{\textbf{微分方程数值解第一次作业}}
\date{\today}

\begin{document}
\subsection*{\uppercase\expandafter{\romannumeral 1}} Exercise 7.13
\begin{proof}
    Since $||g||_\infty = \max_{1\leq i \leq N}\left|g_i\right|$, and $O(h)>O(h^2)$, 
    then $||g||_\infty = O(h)$.

    Since $||g||_1 = h\sum_{i=1}^{N}\left|g_i\right|=h(O(h)+(N-1)O(h^2)+O(h))$, and $O(h) > O(h^2), hO(h) = O(h^2)$, 
    then $||g||_1 = O(h^2)$ 

    Since $||g||_2=(h\sum_{i=1}^{N}\left|g_i\right|^2)^\frac{1}{2}$, and $(O(h))^2=O(h^2),O(h^2)>O(h^4)$, 
    then $||g||_2 = (hO(h^2))^\frac{1}{2}=O(h^\frac{3}{2})$

\end{proof}

\subsection*{\uppercase\expandafter{\romannumeral 2}} Exercise 7.34
\begin{proof}
    Assume the first column of $B_E$ is $b_q = (x_0, x_1,\cdots, x_{m+1})$. Then by $A_Eb_1=e_1$, we have
    $$\left\{\begin{aligned}
        &-x_0+x_1=h\\
        &x_i-2x_{i+1}+x_{i+2}=0,i={1,2,\cdots,m-1}\\
        &x_{m+1} = 0
    \end{aligned}\right .$$
    Then we have $x_i = -(m+1-i)h$, that is $b_{11}=x_1=-(m+1)h=-1=O(1)$.
\end{proof}

\subsection*{\uppercase\expandafter{\romannumeral 3}} Exercise  7.39
\begin{proof}
    Note $$D_x^2(x_i,y_j) = -\frac{U_{i-1,j}-2U_{ij}+U_{i+1,j}}{h^2},D_y^2(x_i,y_j)=-\frac{U_{i,j-1}-2U_{ij}+U_{i,j-1}}{h^2}.$$

    By Example 7.15, we have 
    $$\begin{aligned}
        \tau_{i,j}&=-D_x^2u(x_i,y_j)-(-u''(x_i,y_j))-D_y^2u(x_i,y_j)-(-u''(x_i,y_j))\\
        &=-\frac{h^2}{12}\frac{\partial^4 u}{\partial x^4}-\frac{h^2}{12}\frac{\partial^4 u}{\partial y^4}+O(h^4)\\
        &=-\frac{h^2}{12}(\frac{\partial^4 u}{\partial x^4}+\frac{\partial^4 u}{\partial y^4})\mid _{(x_i,y_j)}+O(h^4)
    \end{aligned}$$
\end{proof}


\subsection*{\uppercase\expandafter{\romannumeral 4}} Exercise 7.60(Complement)
The LTE at an irregular equation-discretization point is O(h), while the LTE at a regular equation-discretization point is $O(h^2)$
\begin{proof}
    x-axis: Since we have 
    $$\frac{(1+\theta)U_p-U_A-\theta U_w}{\frac{1}{2}\theta(1+\theta)h^2}=\frac{\frac{U_A-U_P}{\theta h}-\frac{U_P-U_W}{h}}{\frac{1}{2}(\theta +1)h}$$
    and
    $$U_A-U_P=U_P'(\theta h)+\frac{U_p''}{2!}(\theta h)^2+\frac{U_p'''}{3!}(\theta h)^3+O(h^3)$$
    $$\theta (U_W-U_P)=U_P'(-\theta h)+\frac{U_p''}{2!}\theta(-h)^2+\frac{U_p'''}{3!}\theta(-h)^3+O(h^3)$$
    then
    $$\frac{(1+\theta)U_p-U_A-\theta U_w}{\frac{1}{2}\theta(1+\theta)h^2}-U_P''=\frac{2U_P'''}{3!}(\theta - 1)h + O$$
    That is
    $$\frac{(1+\theta)U_p-U_A-\theta U_w}{\frac{1}{2}\theta(1+\theta)h^2}-U_{xx}=\frac{2U_{xxx}}{3!}(\theta - 1)h + O$$
    Similarly, we have y axis.
    $$\frac{(1+\alpha)U_p-U_B-\alpha U_S}{\frac{1}{2}\alpha(1+\alpha)h^2}-U_{yy}=\frac{2U_{yyy}}{3!}(\alpha - 1)h + O$$
    Hence,
    $$\tau_p = L_hU_P - U_{xx}-U_{yy} = O(h).$$
\end{proof}


\subsection*{\uppercase\expandafter{\romannumeral 5}} Exercise 7.61
\begin{proof}
    Note $T_{max} = max\{\frac{T_1}{C_1},\frac{T_2}{C_2}\},\psi = E_P+T_m{max}\phi_P$

    Then we have $$L_h\psi \leq -T_P-\frac{T_i}{C_i}C_i\leq 0,P\in X_i$$
    
    Since $max_{P\in X}\psi_P\leq 0,\phi_P\geq 0,E_Q=0,$ by Lemma 7.56, we have 
    $$\begin{aligned}
        E_P&\leq max_{P\in X}(E_P+T_{max}\phi_P)\leq max_{Q\in \partial \Omega}(E_Q+T_{max}\phi _Q)\\
        &=max_{Q\in \partial \Omega}(\phi_Q)max\{\frac{T_1}{C_1},\frac{T_2}{C_2}\}
    \end{aligned}.$$
\end{proof}
\end{document} 